$(function(){
  $('#menu-toggle').click(function(){
    $('#menu').toggleClass('active');
    $(this).toggleClass('active');
  });

  $('#menu .menu-lst a').hover(
    function(){
      var $t = $(this);
      $t.text($t.data('zh'));
    },
    function(){
      var $t = $(this);
      $t.text($t.data('en').toUpperCase());
    }).click(function(){
      var ref = $(this).attr('href');
      var index = $(ref).index();
      $('.page-section').each(function(idx,el){
        if("#"+$(el).attr('id') == ref){
          mousNow = idx;
          //console.log(idx);
        }
      });
    });
});